package personnel.department.dao.entity;

import java.util.Set;

import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Embeddable;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;
import javax.persistence.OneToOne;
import javax.persistence.Table;

@Embeddable
public class Education {
	
	@OneToMany(cascade=CascadeType.ALL)
	@JoinColumn(name="employee_id")
	private Set<Certificate> certificates;
	
	@OneToMany(cascade=CascadeType.ALL)
	@JoinColumn(name="employee_id")
	private Set<Qualification> qualifications;
	
	@OneToMany(cascade=CascadeType.ALL)
	@JoinColumn(name="employee_id")
	private Set<Retraining> retrainings;
	
	@OneToMany(cascade=CascadeType.ALL)
	@JoinColumn(name="employee_id")
	private Set<Validation> validations;
	
	@OneToMany(cascade=CascadeType.ALL)
	@JoinColumn(name="employee_id")
	private Set<Degree> degrees;
	
	@OneToOne(cascade=CascadeType.ALL)
	@JoinColumn(name="medicdiplom_id")
	private Diplom medicDiplom;
	
	@OneToMany(cascade=CascadeType.ALL)
	@JoinColumn(name="employee_id")
	private Set<Internship> internship;
	
	public Education() {
	}
	
	public Set<Certificate> getCertificates() {
		return certificates;
	}

	public void setCertificates(Set<Certificate> certificates) {
		this.certificates = certificates;
	}

	public Set<Qualification> getQualifications() {
		return qualifications;
	}

	public void setQualifications(Set<Qualification> qualifications) {
		this.qualifications = qualifications;
	}

	public Set<Retraining> getRetrainings() {
		return retrainings;
	}

	public void setRetrainings(Set<Retraining> retrainings) {
		this.retrainings = retrainings;
	}

	public Set<Validation> getValidations() {
		return validations;
	}

	public void setValidations(Set<Validation> validations) {
		this.validations = validations;
	}

	public Set<Degree> getDegrees() {
		return degrees;
	}

	public void setDegrees(Set<Degree> degrees) {
		this.degrees = degrees;
	}

	public Diplom getMedicDiplom() {
		return medicDiplom;
	}

	public void setMedicDiplom(Diplom medicDiplom) {
		this.medicDiplom = medicDiplom;
	}

	public Set<Internship> getInternship() {
		return internship;
	}

	public void setInternship(Set<Internship> internship) {
		this.internship = internship;
	}


}
